Fundamental Data Types – Numeric
VectorScript supports three numeric data types: INTEGER, LONGINT, and REAL.
INTEGER
Values of type INTEGER are a subset of the whole numbers. INTEGER values may be in a range of -32767 to 32767, and may not contain any fractional or decimal parts. Numbers which contain fractional or decimal parts will be truncated if assigned to a variable of type INTEGER.
In VectorScript, variables of type INTEGER will only accept INTEGER values or LONGINT values which fall within the valid INTEGER range.
LONGINT
Values of type LONGINT are also a subset of the whole numbers. LONGINT values can represent a larger range of values than the INTEGER type, with the range for LONGINT values spanning from -2,147,183,647 to 2,147,183,647.
LONGINT values, like INTEGER values, may not contain any fractional or decimal parts. Numbers which contain fractional or decimal parts will be truncated if assigned to a variable of type LONGINT. In VectorScript, variables of type LONGINT will accept either LONGINT or INTEGER values.
Arithmetic operations involving values of types INTEGER and LONGINT follow these rules:
*
All integer constants in the valid value range of type INTEGER are considered to be of type INTEGER. All integer constants in the range of type LONGINT, but not in the range of type INTEGER, are considered to be of type LONGINT.
*
When both operands of an operator (or the single operand of a unary operator) are of type INTEGER, the result is of type INTEGER (truncated if it falls outside the range of values which can be represented by that type). Similarly, if both operands are of type LONGINT, the result is of type LONGINT.
*
When one operand is of type LONGINT and the other is of type INTEGER, the INTEGER operand is converted to LONGINT and the result is of type LONGINT. If this value is assigned to a variable of type INTEGER, it is truncated.
REAL
Values of type REAL (also known as floating-point values) are a subset of the real numbers, and can store fractional or decimal parts of a number. Valid REAL values fall within a range of 1.9 x 10e-4951 to 1.1 x 10e4932.
In VectorScript, variables of type REAL will accept REAL, LONGINT, or INTEGER values. LONGINT and INTEGER values will be converted to the REAL data type before being assigned to a variable.

Variables, Constants, and Data Types : VectorScript Data Types : Fundamental Data Types – Numeric

Nemetschek NA
Phone: 410.290.5114
Fax: 410.290.8050